<?php

namespace app\api\controller;

/**
 * @name: 注册
 * @Param: 
 * @Description: 
 * @Author: foo
 * @Date: 2019-11-06 17:13:08
 */
use app\api\service;
class Register extends Base
{
    /**
     * @name: 注册
     * @Param: 
     * @Description: 
     * @Author: foo
     * @Date: 2019-11-06 17:14:26
     */
    function reg ()
    {
        $inputData = $this->filterInput();//输入数据

        file_put_contents('../runtime/register.log', var_export($inputData, true));

        $Register = new service\Register();
        $Register->reg($inputData);//注册

        $data = [
            'host_id' => $Register->host_id,
            'hostkey' => $Register->hostkey,
        ];

        $this->jsonOutPut($data);
    }
}